﻿<UserControl x:Class="Microsoft.Research.ScientificWorkflow.UIDesigner.WaitControl"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    ClipToBounds="True">
    
    <UserControl.Resources>
        <Storyboard x:Key="circleAnimation" RepeatBehavior="Forever"  >
            <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="c1" Storyboard.TargetProperty="(UIElement.Opacity)">
                <SplineDoubleKeyFrame KeyTime="00:00:00" Value="1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.3000000" Value="0.1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:01.5000000" Value="0.1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:01.8000000" Value="1"/>

            </DoubleAnimationUsingKeyFrames>

            <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="c2" Storyboard.TargetProperty="(UIElement.Opacity)">
                <SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.3000000" Value="1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.6000000" Value="0.1"/>
            </DoubleAnimationUsingKeyFrames>

            <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="c3" Storyboard.TargetProperty="(UIElement.Opacity)">
                <SplineDoubleKeyFrame KeyTime="00:00:00.3000000" Value="0.1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.6000000" Value="1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.9000000" Value="0.1"/>
            </DoubleAnimationUsingKeyFrames>

            <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="c6" Storyboard.TargetProperty="(UIElement.Opacity)">
                <SplineDoubleKeyFrame KeyTime="00:00:00.6000000" Value="0.1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:00.9000000" Value="1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:01.2000000" Value="0.1"/>
            </DoubleAnimationUsingKeyFrames>

            <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="c5" Storyboard.TargetProperty="(UIElement.Opacity)">
                <SplineDoubleKeyFrame KeyTime="00:00:00.9000000" Value="0.1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:01.2000000" Value="1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:01.5000000" Value="0.1"/>
            </DoubleAnimationUsingKeyFrames>

            <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="c4" Storyboard.TargetProperty="(UIElement.Opacity)">
                <SplineDoubleKeyFrame KeyTime="00:00:01.2000000" Value="0.1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:01.5000000" Value="1"/>
                <SplineDoubleKeyFrame KeyTime="00:00:01.8000000" Value="0.1"/>
            </DoubleAnimationUsingKeyFrames>
        </Storyboard>
    </UserControl.Resources>
    
    <UserControl.Triggers>
        <EventTrigger RoutedEvent="FrameworkElement.Loaded">
            <BeginStoryboard Storyboard="{StaticResource circleAnimation}"/>
        </EventTrigger>
    </UserControl.Triggers>

    <Border Height="40" Padding="3,5,15,5" VerticalAlignment="Center" HorizontalAlignment="Center" BorderBrush="{x:Null}" Background="#7F787878" CornerRadius="5">
        <StackPanel Orientation="Horizontal" HorizontalAlignment="Left" VerticalAlignment="Center">
            <Grid Height="60" Width="60" HorizontalAlignment="Left" VerticalAlignment="Center">
                <Ellipse Fill="#FFFFFFFF" Stroke="{x:Null}" HorizontalAlignment="Left" Margin="16.721,21.871,0,0" VerticalAlignment="Top" Width="6" Height="6" x:Name="c1" Opacity="0.1"/>
                <Ellipse Fill="#FFFFFFFF" Stroke="{x:Null}" Margin="28.153,16.769,25.847,0" Height="6" VerticalAlignment="Top" x:Name="c2" Opacity="0.1"/>
                <Ellipse Fill="#FFFFFFFF" Stroke="{x:Null}" HorizontalAlignment="Right" Margin="0,24.423,17.462,29.577" Width="6" Height="6" x:Name="c3" Opacity="0.1"/>
                <Ellipse Fill="#FFFFFFFF" Stroke="{x:Null}" HorizontalAlignment="Right" Margin="0,0,20,18.381" Width="6" Height="6" VerticalAlignment="Bottom" RenderTransformOrigin="0.5,0.5" x:Name="c6" Opacity="0.1">
                    <Ellipse.RenderTransform>
                        <TransformGroup>
                            <ScaleTransform ScaleX="1" ScaleY="1"/>
                            <SkewTransform AngleX="0" AngleY="0"/>
                            <RotateTransform Angle="0"/>
                            <TranslateTransform X="0" Y="0"/>
                        </TransformGroup>
                    </Ellipse.RenderTransform>
                </Ellipse>
                <Ellipse Fill="#FFFFFFFF" Stroke="{x:Null}" Margin="25,0,29,14.961" Height="6" VerticalAlignment="Bottom" RenderTransformOrigin="0.5,0.5" x:Name="c5" Opacity="0.1">
                    <Ellipse.RenderTransform>
                        <TransformGroup>
                            <ScaleTransform ScaleX="1" ScaleY="1"/>
                            <SkewTransform AngleX="0" AngleY="0"/>
                            <RotateTransform Angle="0"/>
                            <TranslateTransform X="0" Y="0"/>
                        </TransformGroup>
                    </Ellipse.RenderTransform>
                </Ellipse>
                <Ellipse Fill="#FFFFFFFF" Stroke="{x:Null}" HorizontalAlignment="Left" Margin="15,0,0,20.804" Width="6" Height="6" VerticalAlignment="Bottom" RenderTransformOrigin="0.5,0.5" x:Name="c4" Opacity="0.1">
                    <Ellipse.RenderTransform>
                        <TransformGroup>
                            <ScaleTransform ScaleX="1" ScaleY="1"/>
                            <SkewTransform AngleX="0" AngleY="0"/>
                            <RotateTransform Angle="0"/>
                            <TranslateTransform X="0" Y="0"/>
                        </TransformGroup>
                    </Ellipse.RenderTransform>
                </Ellipse>
            </Grid>
            <TextBlock Name="txtBxMsg" TextWrapping="NoWrap" TextTrimming="CharacterEllipsis" HorizontalAlignment="Left" VerticalAlignment="Center" Foreground="#FFFFFFFF"/>
		</StackPanel>
    </Border>
</UserControl>
